import VueRouter from 'vue-router'
//导入路由模块
import Home from './components/tabbar/HomeContainer.vue'
import Member from './components/tabbar/MemberContainer.vue'
import ShopCart from './components/tabbar/ShopCartContainer.vue'
import Search from './components/tabbar/SearchContainer.vue'
import NewList from './components/news/NewsList.vue'
import NewInfo from './components/news/NewsInfo.vue'
import PhotoList from'./components/photos/PhotoList.vue'
import PhotoInfo from './components/photos/PhotoInfo.vue'
import GoodsList from './components/goods/GoodsList.vue'
import GoodsInfo from './components/goods/GoodsInfo.vue'
import GoodsDesc from './components/goods/GoodsDesc.vue'
import GoodsComment from './components/goods/GoodsComment.vue'
//书写路由模块
var router =new VueRouter({
	routes:[
		{path:'/',redirect:'/home'},
		{path:'/home',component:Home},
		{path:'/member',component:Member},
		{path:'/shopcart',component:ShopCart},
		{path:'/search',component:Search},
		{path:'/home/newsList',component:NewList},
		{path:'/home/newsInfo/:id',component:NewInfo},
		{path:'/home/photoList',component:PhotoList},
		{path:'/home/photoInfo/:id',component:PhotoInfo},
		{path:'/home/goodsList',component:GoodsList},
		{path:'/home/goodsInfo/:id',component:GoodsInfo},
		{path:'/home/goodsDesc/:id',component:GoodsDesc},
		{path:'/home/goodsComment/:id',component:GoodsComment}
	],
	linkActiveClass:'mui-active'
})

export default router